<?php

/**
 * admin actions.
 *
 * @package    retailbrain
 * @subpackage admin
 * @author     Your name here
 * @version    SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class adminActions extends sfActions {
    
    
    /**
     * Termina la session por inactividad
     */
    public function preExecute() {
        if (!$this->getUser()->isAuthenticated()) {
            $this->getUser()->setAuthenticated(false);
            $this->getUser()->getAttributeHolder()->clear();
            $this->redirect('/login');
        }
    }

    /**
     * Executes index action
     *
     * @param sfRequest $request A request object
     */
    public function executeIndex(sfWebRequest $request) {

        $this->getResponse()->setSlot('title', 'Administración');
        $this->breadcrumbs = array(array("Administración", "admin/index"));
        
        $this->caps = $this->getUser()->getAttribute('caps');
    }

    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
   
    
    
    
    
    
    
    
}
